﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="BillInformationValidation.aspx.cs" Inherits="WorkShop.WorkShop.BillInformationValidation" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Bill Information Validation</title>
</head>
<body>
    <form id="frmBillInformationValidation" runat="server">
        <div style =" margin-left: 30px">
            <h2>Wellcome,
                <asp:Label ID="lblUserID" runat="server" Text="[lblUserID]"></asp:Label>
            </h2>
            <h2>Billing Information:</h2>
            <asp:Panel ID="Panel1" runat="server" Height="356px" Width="750px">
                <asp:Label ID="lblFname" runat="server" Text="First Name : " Width="130px"></asp:Label>
                <asp:TextBox ID="txtFname" runat="server"></asp:TextBox>
                <asp:RequiredFieldValidator ID="valFirstName" runat="server" ErrorMessage="Please enter the first name" ForeColor="Red" SetFocusOnError="True" ControlToValidate="txtFname"></asp:RequiredFieldValidator>
                <br />
                <br />
                <asp:Label ID="lblFname0" runat="server" Text="Last Name :" Width="130px"></asp:Label>
                <asp:TextBox ID="txtLastName" runat="server"></asp:TextBox>
                <asp:RequiredFieldValidator ID="valLastName" runat="server" ErrorMessage="Please enter the last name" ForeColor="Red" SetFocusOnError="True" ControlToValidate="txtLastName"></asp:RequiredFieldValidator>
                <br />
                <br />
                <asp:Label ID="lblFname1" runat="server" Text="Email : " Width="130px"></asp:Label>
                <asp:TextBox ID="txtEmail" runat="server"></asp:TextBox>
                <asp:RequiredFieldValidator ID="valEmail" runat="server" ErrorMessage="Please enter your  e-mail address" ForeColor="Red" SetFocusOnError="True" ControlToValidate="txtEmail"></asp:RequiredFieldValidator>
                <br />
                <br />
                <asp:Label ID="lblFname2" runat="server" Text="City :" Width="130px"></asp:Label>
                <asp:TextBox ID="txtCity" runat="server"></asp:TextBox>
                <asp:RequiredFieldValidator ID="valCity" runat="server" ErrorMessage="Please enter your city." ForeColor="Red" SetFocusOnError="True" ControlToValidate="txtCity"></asp:RequiredFieldValidator>
                <br />
                <br />
                <asp:Label ID="lblFname3" runat="server" Text="State :" Width="130px"></asp:Label>
                <asp:TextBox ID="txtState" runat="server"></asp:TextBox>
                <asp:RequiredFieldValidator ID="valState" runat="server" ErrorMessage="Please enter your state" ForeColor="Red" SetFocusOnError="True" ControlToValidate="txtState"></asp:RequiredFieldValidator>
                <br />
                <br />
                <asp:Label ID="lblFname4" runat="server" Text="Country : " Width="130px"></asp:Label>
                <asp:TextBox ID="txtCountry" runat="server"></asp:TextBox>
                <asp:RequiredFieldValidator ID="valCountry" runat="server" ErrorMessage="Please enter your country." ForeColor="Red" SetFocusOnError="True" ControlToValidate="txtCountry"></asp:RequiredFieldValidator>
                <br />
                <br />
                <asp:Label ID="lblFname5" runat="server" Text="ZipCode :" Width="130px"></asp:Label>
                <asp:TextBox ID="txtZipCode" runat="server"></asp:TextBox>
                <asp:RequiredFieldValidator ID="valZipCode" runat="server" ErrorMessage="Please enter zip code." ForeColor="Red" SetFocusOnError="True" ControlToValidate="txtZipCode"></asp:RequiredFieldValidator>
                <br />
                `<br />
                <asp:CompareValidator ID="valZipCodeForm" runat="server" ErrorMessage="Please enter zip code in numeric format." ForeColor="Red" Operator="DataTypeCheck" SetFocusOnError="True" Type="Integer" ControlToValidate="txtZipCode"></asp:CompareValidator>
                <br />                
            </asp:Panel>
            <h3>Payment Information:</h3>
            <asp:Panel ID="Panel2" runat="server" Height="109px" Width="751px">
                <asp:Label ID="lblCreditCard" runat="server" Text="Credit Card :" Width="140px"></asp:Label>
                <asp:DropDownList ID="ddlCreditCard" runat="server" Height="16px" Width="145px">
                    <asp:ListItem Value="0">Select</asp:ListItem>
                    <asp:ListItem>MasterCard</asp:ListItem>
                    <asp:ListItem>AltaVista</asp:ListItem>
                </asp:DropDownList>
                <asp:RequiredFieldValidator ID="valCreditCard" runat="server" ControlToValidate="ddlCreditCard" Display="Dynamic" ErrorMessage="Please select any credit card." ForeColor="Red" InitialValue="0"></asp:RequiredFieldValidator>
                <br />
                <br />
                <asp:Label ID="lblCreditCardNumber" runat="server" Text="Credit Card Number : " Width="140px"></asp:Label>
                <asp:TextBox ID="txtCreditCardNumber" runat="server" Width="145px"></asp:TextBox>
                <asp:RequiredFieldValidator ID="valCreditCardNumber" runat="server" ControlToValidate="txtCreditCardNumber" Display="Dynamic" ErrorMessage="Please enter credit card number." ForeColor="Red" SetFocusOnError="True"></asp:RequiredFieldValidator>
                <br />
                <br />
                <asp:CompareValidator ID="valCreditCardNumberFormat" runat="server" ErrorMessage="Please enter credit card number  in numberic format." ForeColor="Red" Operator="DataTypeCheck" Type="Integer" ControlToValidate="txtCreditCardNumber"></asp:CompareValidator>
            </asp:Panel>

            <asp:Button ID="btnSubmit" runat="server" Text="Submit" OnClick="btnSubmit_Click" />
            &nbsp;
            <asp:Button ID="btnReset" runat="server" Text="Reset" OnClick="btnReset_Click" />
        </div>
    </form>
</body>
</html>
